<template>
    <div>
        <p>count:{{ $props.conut }}</p>
        <p>countText：{{ $props.countText }}</p>
        <button @click="haldeClick">改变</button>
    </div>
</template>

<script setup lang="ts">
    import { ref } from 'vue'
    const $props = defineProps({
        conut: Number,
        countText: String,
    })
    const num = ref(0)
    const $emit = defineEmits(['update:count', 'update:countText'])
    const haldeClick = () => {
        $emit('update:count', num.value + 1)
        $emit('update:countText', 'countText' + num.value)
    }
</script>
<style lang="scss" scoped></style>
